<script>
	export default {
		onLaunch: function() {
			console.log('App Launch')
			this.$store.dispatch('city/initLocAct') //触发地理位置定位
			// 从本地存储提取并初始化购物车数据
			uni.getStorage({
				key:'cartList',
				success: (res) => {
					this.$store.commit('cart/cartInitMut',res.data)
				}
			})
			//从本地存储提取用户信息并初始化
			uni.getStorage({
				key:'userInfo',
				success: (res) => {
					this.$store.commit('user/initInfoMut',res.data)
				}
			})
		},
		onShow: function() {
			console.log('App Show')
		},
		onHide: function() {
			console.log('App Hide')
		}
	}
</script>

<style lang="scss">
	/*每个页面公共css */
	@import url('colorui/icon.css');
	@import url('colorui/main.css');
	@import url('./static/font/iconfont.css');
	@import './tuniao-ui/index.scss';
    @import './tuniao-ui/iconfont.css';
	
</style>
